package main

import "fmt"

func main() {
	//正常代码
	const pi float64 = 3.1415
	var r float64
	var s float64
	var round float64
	for {
		fmt.Println("输入半径r:")
		fmt.Scan(&r)
		if r > 20 {
			fmt.Println("无法计算20以上半径的圆形的面积和周长...")
		} else if r < 0 {
			fmt.Println("您输入的圆形半径不合法.....")
		} else {
			s = pi * r * r
			round = 2 * pi * r
			fmt.Printf("圆形的半径:%v,面积:%v,周长:%v\n", r, s, round)
			break
		}
	}

	//pi = 3.20 //err,const not changed

}
